package com.molichuxing.services.business.service;

import com.molichuxing.framework.dto.Paged;
import com.molichuxing.services.business.dto.request.modify.YearlyInspectionModifyBizDto;
import com.molichuxing.services.business.dto.response.CarYearlyInspectDto;
import com.molichuxing.services.business.dto.response.YearlyInspectionBizDto;
import com.molichuxing.services.business.dto.response.YearlyInspectionLogBizDto;
import com.molichuxing.services.infrastructure.dto.request.create.YearlyInspectionCreateDto;
import com.molichuxing.services.infrastructure.dto.request.modify.YearlyInspectionModifyDto;
import com.molichuxing.services.property.CarYearlyInspectStatusEnum;

import java.util.List;

/**
 * 车辆年检信息服务类
 * @author xuelin yi
 */
public interface CarYearlyInspectionBizService {

    /**
     * 根据查询条件获取年检列表信息
     * @param carYearlyInspectStatusEnum
     * @param licencePlate
     * @param vin
     * @param stockId
     * @param inspectStartDate
     * @param inspectEndDate
     * @param pageNum
     * @param pageSize
     * @return
     */
    public Paged<CarYearlyInspectDto> getYearlyInspect(CarYearlyInspectStatusEnum carYearlyInspectStatusEnum, String licencePlate, String vin, Integer stockId
            , String inspectStartDate, String inspectEndDate,Integer handleStatus, String sortName, String sortWay, Integer pageNum, Integer pageSize);

    /**
     * 新增年检信息
     * @param createDto
     * @return
     */
    public int createYearlyInspection(YearlyInspectionCreateDto createDto) throws Exception;

    /**
     * 编辑年检信息
     * @param modifyDto
     * @return
     */
    public Boolean modifyYearlyInspection(YearlyInspectionModifyDto modifyDto) throws Exception;

    /**
     * 获取年检
     *
     * @param carId
     * @return
     */
    public YearlyInspectionBizDto getYearlyInspection(Integer carId);

    /**
     * 年检导出
     * @param carYearlyInspectStatusEnum
     * @param licencePlate
     * @param vin
     * @param stockId
     * @param inspectStartDate
     * @param inspectEndDate
     * @return
     */
    public List<CarYearlyInspectDto> getYearlyInspectDownload(List<String> inspectionIdList,CarYearlyInspectStatusEnum carYearlyInspectStatusEnum, String licencePlate, String vin, Integer stockId
            , String inspectStartDate, String inspectEndDate);

    public long getYearlyInspectDownloadCount(List<String> inspectionIdList,CarYearlyInspectStatusEnum carYearlyInspectStatusEnum, String licencePlate, String vin, Integer stockId
            , String inspectStartDate, String inspectEndDate);


    /**
     * 年检记录
     *
     * @param carId
     * @return
     */
    public List<YearlyInspectionLogBizDto> getYearlyInspectionLogListByCarId(Integer carId);

    /**
     * 修改年检信息
     *
     * @return
     */
    public Boolean modifyYearlyInspection(List<YearlyInspectionModifyBizDto> yearlyInspectionModifyList);

}
